<!DOCTYPE html>












  


<html class="theme-next muse use-motion" lang="zh-Hans">
<head>
  <meta charset="UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=2"/>
<meta name="theme-color" content="#222">












<meta http-equiv="Cache-Control" content="no-transform" />
<meta http-equiv="Cache-Control" content="no-siteapp" />






















<link href="/lib/font-awesome/css/font-awesome.min.css?v=4.6.2" rel="stylesheet" type="text/css" />

<link href="/css/main.css?v=6.4.0" rel="stylesheet" type="text/css" />


  <link rel="apple-touch-icon" sizes="180x180" href="/images/apple-touch-icon-next.png?v=6.4.0">


  <link rel="icon" type="image/png" sizes="32x32" href="/images/favicon-32x32-next.png?v=6.4.0">


  <link rel="icon" type="image/png" sizes="16x16" href="/images/favicon-16x16-next.png?v=6.4.0">


  <link rel="mask-icon" href="/images/logo.svg?v=6.4.0" color="#222">









<script type="text/javascript" id="hexo.configurations">
  var NexT = window.NexT || {};
  var CONFIG = {
    root: '/',
    scheme: 'Muse',
    version: '6.4.0',
    sidebar: {"position":"left","display":"post","offset":12,"b2t":false,"scrollpercent":false,"onmobile":false},
    fancybox: false,
    fastclick: false,
    lazyload: false,
    tabs: true,
    motion: {"enable":true,"async":false,"transition":{"post_block":"fadeIn","post_header":"slideDownIn","post_body":"slideDownIn","coll_header":"slideLeftIn","sidebar":"slideUpIn"}},
    algolia: {
      applicationID: '',
      apiKey: '',
      indexName: '',
      hits: {"per_page":10},
      labels: {"input_placeholder":"Search for Posts","hits_empty":"We didn't find any results for the search: ${query}","hits_stats":"${hits} results found in ${time} ms"}
    }
  };
</script>


  




  <meta name="description" content="上一篇文章对ThreadLocal的简单入门，了解了使用场景和使用办法。接下来我们继续聊聊：  ThreadLocal的内部结构！ ThreadLocal中的WeakReference是什么？ ThreadLocal是否会触发内存泄露？   纸上得来终觉浅，绝知此事要躬行 。">
<meta name="keywords" content="ThreadLocal">
<meta property="og:type" content="article">
<meta property="og:title" content="ThreadLocal自我总结（二）">
<meta property="og:url" content="http://yoursite.com/2018/04/24/thread-local-2/index.html">
<meta property="og:site_name" content="ThinkMore">
<meta property="og:description" content="上一篇文章对ThreadLocal的简单入门，了解了使用场景和使用办法。接下来我们继续聊聊：  ThreadLocal的内部结构！ ThreadLocal中的WeakReference是什么？ ThreadLocal是否会触发内存泄露？   纸上得来终觉浅，绝知此事要躬行 。">
<meta property="og:locale" content="zh-Hans">
<meta property="og:image" content="http://p5h71khzd.bkt.clouddn.com/ThreadLocal%20%281%29.png">
<meta property="og:image" content="http://p5h71khzd.bkt.clouddn.com/ThreadLocal%20%282%29.png">
<meta property="og:updated_time" content="2018-07-09T02:48:36.943Z">
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="ThreadLocal自我总结（二）">
<meta name="twitter:description" content="上一篇文章对ThreadLocal的简单入门，了解了使用场景和使用办法。接下来我们继续聊聊：  ThreadLocal的内部结构！ ThreadLocal中的WeakReference是什么？ ThreadLocal是否会触发内存泄露？   纸上得来终觉浅，绝知此事要躬行 。">
<meta name="twitter:image" content="http://p5h71khzd.bkt.clouddn.com/ThreadLocal%20%281%29.png">






  <link rel="canonical" href="http://yoursite.com/2018/04/24/thread-local-2/"/>



<script type="text/javascript" id="page.configurations">
  CONFIG.page = {
    sidebar: "",
  };
</script>

  <title>ThreadLocal自我总结（二） | ThinkMore</title>
  






  <script type="text/javascript">
    var _hmt = _hmt || [];
    (function() {
      var hm = document.createElement("script");
      hm.src = "https://hm.baidu.com/hm.js?13172698bcdb7ab00b7d3ec112aae9c1";
      var s = document.getElementsByTagName("script")[0];
      s.parentNode.insertBefore(hm, s);
    })();
  </script>




  <noscript>
  <style type="text/css">
    .use-motion .motion-element,
    .use-motion .brand,
    .use-motion .menu-item,
    .sidebar-inner,
    .use-motion .post-block,
    .use-motion .pagination,
    .use-motion .comments,
    .use-motion .post-header,
    .use-motion .post-body,
    .use-motion .collection-title { opacity: initial; }

    .use-motion .logo,
    .use-motion .site-title,
    .use-motion .site-subtitle {
      opacity: initial;
      top: initial;
    }

    .use-motion {
      .logo-line-before i { left: initial; }
      .logo-line-after i { right: initial; }
    }
  </style>
</noscript>

</head>

<body itemscope itemtype="http://schema.org/WebPage" lang="zh-Hans">

  
  
    
  

  <div class="container sidebar-position-left page-post-detail">
    <div class="headband"></div>

    <header id="header" class="header" itemscope itemtype="http://schema.org/WPHeader">
      <div class="header-inner"><div class="site-brand-wrapper">
  <div class="site-meta ">
    

    <div class="custom-logo-site-title">
      <a href="/" class="brand" rel="start">
        <span class="logo-line-before"><i></i></span>
        <span class="site-title">ThinkMore</span>
        <span class="logo-line-after"><i></i></span>
      </a>
    </div>
    
      
        <p class="site-subtitle">驽马十驾,功在不舍！</p>
      
    
  </div>

  <div class="site-nav-toggle">
    <button aria-label="Toggle navigation bar">
      <span class="btn-bar"></span>
      <span class="btn-bar"></span>
      <span class="btn-bar"></span>
    </button>
  </div>
</div>



<nav class="site-nav">
  
    <ul id="menu" class="menu">
      
        
        
        
          
          <li class="menu-item menu-item-home">
    <a href="/" rel="section">
      <i class="menu-item-icon fa fa-fw fa-home"></i> <br />Home</a>
  </li>
        
        
        
          
          <li class="menu-item menu-item-archives">
    <a href="/archives/" rel="section">
      <i class="menu-item-icon fa fa-fw fa-archive"></i> <br />Archives</a>
  </li>

      
      
    </ul>
  

  
    

  

  
</nav>



  



</div>
    </header>

    


    <main id="main" class="main">
      <div class="main-inner">
        <div class="content-wrap">
          
          <div id="content" class="content">
            

  <div id="posts" class="posts-expand">
    

  

  
  
  

  

  <article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
  
  
  
  <div class="post-block">
    <link itemprop="mainEntityOfPage" href="http://yoursite.com/2018/04/24/thread-local-2/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="文敦复">
      <meta itemprop="description" content="思考的懒惰是真的懒惰！">
      <meta itemprop="image" content="/images/avatar.gif">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="ThinkMore">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">ThreadLocal自我总结（二）
              
            
          </h1>
        

        <div class="post-meta">
          <span class="post-time">

            
            
            

            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">Posted on</span>
              

              
                
              

              <time title="Created: 2018-04-24 20:39:30" itemprop="dateCreated datePublished" datetime="2018-04-24T20:39:30+08:00">2018-04-24</time>
            

            
              

              
                
                <span class="post-meta-divider">|</span>
                

                <span class="post-meta-item-icon">
                  <i class="fa fa-calendar-check-o"></i>
                </span>
                
                  <span class="post-meta-item-text">Edited on</span>
                
                <time title="Modified: 2018-07-09 10:48:36" itemprop="dateModified" datetime="2018-07-09T10:48:36+08:00">2018-07-09</time>
              
            
          </span>

          
            <span class="post-category" >
            
              <span class="post-meta-divider">|</span>
            
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              
                <span class="post-meta-item-text">In</span>
              
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing"><a href="/categories/多线程/" itemprop="url" rel="index"><span itemprop="name">多线程</span></a></span>

                
                
              
            </span>
          

          
            
          

          
          

          

          

          

        </div>
      </header>
    

    
    
    
    <div class="post-body" itemprop="articleBody">

      
      

      
        <p>上一篇文章对<code>ThreadLocal</code>的简单入门，了解了使用场景和使用办法。接下来我们继续聊聊：</p>
<ul>
<li><code>ThreadLocal</code>的内部结构！</li>
<li><code>ThreadLocal</code>中的<code>WeakReference</code>是什么？</li>
<li><code>ThreadLocal</code>是否会触发内存泄露？</li>
</ul>
<blockquote>
<p>纸上得来终觉浅，绝知此事要躬行 。</p>
</blockquote>
<a id="more"></a>
<h1 id="内部结构"><a href="#内部结构" class="headerlink" title="内部结构"></a>内部结构</h1><h2 id="分析一"><a href="#分析一" class="headerlink" title="分析一"></a>分析一</h2><p><code>ThreadLocal</code>的内部结构是什么样子的了？我们先上一张带有结论性的图：</p>
<p><img src="http://p5h71khzd.bkt.clouddn.com/ThreadLocal%20%281%29.png" alt="ThreadLocal 图1"></p>
<p>这个图我们可以看出几个东西：</p>
<ol>
<li>每一个<code>Thread</code> 都包含了一个 <code>ThreadLocalMap</code>。</li>
<li>每一个<code>ThreadLocalMap</code>中<code>key</code>是<code>ThreadLocal</code> 而<code>value</code>是 在线程中共享的值。</li>
</ol>
<p>相关代码细节如下所示：</p>
<p>Thread类中有一句关键代码可以证明的我观点1：</p>
<figure class="highlight java"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br></pre></td><td class="code"><pre><span class="line"><span class="keyword">public</span> <span class="class"><span class="keyword">class</span> <span class="title">Thread</span> <span class="keyword">implements</span> <span class="title">Runnable</span> </span>&#123;    </span><br><span class="line">	<span class="comment">// Thread 代码中有如下一句代码，可以看出每一个 Thread 对象都有一个 ThreadLocalMap</span></span><br><span class="line">    ThreadLocal.ThreadLocalMap threadLocals = <span class="keyword">null</span>;</span><br><span class="line">&#125;</span><br></pre></td></tr></table></figure>
<p>而 <code>ThreadLocalMap</code> 是一个<code>ThreadLocal</code>中的静态类，其中的 Entry 可以证明我的观点2：</p>
<blockquote>
<p>这里为什么要将 <code>ThreadLocalMap</code> 设计为 <code>static</code> 思考中…</p>
</blockquote>
<figure class="highlight java"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br></pre></td><td class="code"><pre><span class="line"><span class="keyword">public</span> <span class="class"><span class="keyword">class</span> <span class="title">ThreadLocal</span>&lt;<span class="title">T</span>&gt; </span>&#123;   </span><br><span class="line">    <span class="comment">// 省略其他。。。</span></span><br><span class="line">	<span class="keyword">static</span> <span class="class"><span class="keyword">class</span> <span class="title">ThreadLocalMap</span> </span>&#123;</span><br><span class="line">        </span><br><span class="line">        <span class="keyword">static</span> <span class="class"><span class="keyword">class</span> <span class="title">Entry</span> <span class="keyword">extends</span> <span class="title">WeakReference</span>&lt;<span class="title">ThreadLocal</span>&lt;?&gt;&gt; </span>&#123;</span><br><span class="line">            <span class="comment">/** The value associated with this ThreadLocal. */</span></span><br><span class="line">            Object value;</span><br><span class="line"></span><br><span class="line">            Entry(ThreadLocal&lt;?&gt; k, Object v) &#123;</span><br><span class="line">                <span class="keyword">super</span>(k);</span><br><span class="line">                value = v;</span><br><span class="line">            &#125;</span><br><span class="line">        &#125;</span><br><span class="line">    &#125;</span><br><span class="line">&#125;</span><br></pre></td></tr></table></figure>
<p>上述分析一看懂后，我们继续来查看分析二。</p>
<h2 id="分析二"><a href="#分析二" class="headerlink" title="分析二"></a>分析二</h2><p><img src="http://p5h71khzd.bkt.clouddn.com/ThreadLocal%20%282%29.png" alt="ThreadLocal 示意图"></p>
<ul>
<li>图2要比图1要复杂点，但更合理些。</li>
<li>图2中左边是栈，右边是堆。栈中保存了2个指向堆的引用：<code>ThreadLocal Ref</code>和<code>Thread Ref</code>。</li>
<li><code>ThreadLocalMap</code> 中 <code>Key</code>是 <code>ThreadLocal</code>，请注意那个红色的虚线，他是<code>WeakReference</code>。这点可以从上述的代码可以看出。</li>
</ul>
<p>不知道大家有没有考虑过这个地方key 为什么要设置成：<code>WeakReference</code>，大家可以先思考，后面会有解答！</p>
<h1 id="引用的4个类型"><a href="#引用的4个类型" class="headerlink" title="引用的4个类型"></a>引用的4个类型</h1><p>Java 中数据类型往大了讲可以分为2个类型：普通类型和引用类型。</p>
<p>普通类型包括：int、byte、short 这些基本类型 因为其结构和内存占用小，所以存放在栈中。</p>
<p>引用类型包括：String、数组、Class等，这些类型通常会比较大，所以通常会在栈中存放指向堆中的引用。</p>
<p>其实细分引用类型还可以分出4类来：</p>
<ul>
<li>强引用：就是我们平时使用的引用。</li>
<li>软引用：<code>SoftReference</code>，其特性为只有当系统内不能不足的时候， 发生GC才会清理掉。</li>
<li>弱引用：<code>WeakReference</code> ，这个一个很脆弱的引用，<strong>当引用的对象仅仅被<code>WeakReference</code>引用的时候</strong>，JVM 一旦 GC 他肯定会被 GC 掉。【请注意我加粗的这句话！】</li>
<li>虚引用：<code>VirtualReference</code>，这个引用基本没有使用过。</li>
</ul>
<p>这里我们谈谈<code>WeakReference</code>和<code>SoftReference</code>他们的不同。</p>
<p>前者是 GC一旦工作就会被清理，后者却是不一定的。</p>
<blockquote>
<p>关于引用软引用和虚引用，我会找个时间在后面补充完善下。</p>
</blockquote>
<h1 id="为什么要使用WeakReference"><a href="#为什么要使用WeakReference" class="headerlink" title="为什么要使用WeakReference"></a>为什么要使用WeakReference</h1><p>为什么要使用<code>WeakReference</code>？其目的是：<strong>为了进一步的防止<code>内存泄漏</code></strong>.</p>
<p>Java的<code>GC</code>是通过<code>可达性性算法</code>来判定哪些对象可以被 GC 的：如果一个对象被引用，那么就不会被 GC 清理。</p>
<p>如果<code>ThreadLocalMap</code> 中的 <code>ThreadLocal</code> 不是<code>WeakReference</code> ，意味着原对象肯定有一层引用在 <code>ThreadLocalMap</code> 中，根据可达性算法 分析那么该对象肯定不会被<code>GC</code>。</p>
<p>但是一旦使用了 <code>WeakReference</code> 在可达性算法分析的时候就会忽略这个引用，当原对象没有被其他对象引用，仅仅被忽略的 <code>WeakReference</code> 引用的时候，原对象就会被 <code>GC</code> 掉，释放了内存空间，减少了内存泄露的发生可能性。</p>
<p>同时我们需要知道：存在于 <code>ThreadLocal</code> 中的对象因为可能被 <code>GC</code> ，所以不一定可以拿到，所以说不应该将<strong>非常重要</strong>的数据存在在 <code>ThreadLocal</code> 中。</p>
<blockquote>
<p>关于我最后提到的一点：：存在于 <code>ThreadLocal</code> 中的对象因为可能被 <code>GC</code> 。我暂时无法通过代码重现，如果你能重现，请不吝赐教。</p>
</blockquote>
<h1 id="内存泄露风险"><a href="#内存泄露风险" class="headerlink" title="内存泄露风险"></a>内存泄露风险</h1><p>在上面提到过，每个<code>Thread</code>中都存在一个map, map的类型是<code>ThreadLocal.ThreadLocalMap.Map</code>中的key为一个<code>ThreadLocal</code>实例. 这个<code>Map</code>的确使用了弱引用,不过弱引用只是针对<code>key</code>. 每个<code>key</code>都弱引用指向<code>ThreadLocal</code>. 当把<code>ThreadLocal</code>实例置为null以后,没有任何强引用指向<code>ThreadLocal</code>实例,所以<code>ThreadLocal</code>将会被<code>gc</code>回收.</p>
<p>但是,我们的value却不能回收,因为存在一条从<code>Current Thread</code>连接过来的强引用。 只有当前<code>Thread</code>结束以后, <code>Current Thread</code>就不会存在栈中,强引用断开, <code>Current Thread</code>, <code>value</code>将全部被<code>GC</code>回收.  　　</p>
<p>所以得出一个结论就是只要这个线程对象被<code>GC</code>回收，就不会出现内存泄露，但在<code>ThreadLocal</code>设为null和线程结束这段时间之前，该对象不会被回收由此可能存在内存泄露的风险。</p>
<h1 id="总结"><a href="#总结" class="headerlink" title="总结"></a>总结</h1><p>本文从内存结构讲到了引用类型的区别，同时提到了ThreadLocal 可能存在的内存泄漏。</p>
<p>本人写这篇文章也是再不停的思考、总结，所以你大可不必要求自己一次看懂，多多查看同类型文章，触类旁通，沉淀知识形成自己的知识体系。</p>
<p>驽马十驾功在不舍！</p>
<blockquote>
<p>您有任何建议和意见，请Email联系: <a href="mailto:hicode_club@163.com" target="_blank" rel="noopener">hicode_club@163.com</a></p>
<p>转载请保留出处 <a href="http://www.hicode.club" target="_blank" rel="noopener">HiCode 俱乐部</a></p>
</blockquote>

      
    </div>

    

    
    
    

    

    

    

    <footer class="post-footer">
      

      
      
      

      
        <div class="post-nav">
          <div class="post-nav-next post-nav-item">
            
              <a href="/2018/04/22/thread-local-1/" rel="next" title="ThreadLocal自我总结（一）">
                <i class="fa fa-chevron-left"></i> ThreadLocal自我总结（一）
              </a>
            
          </div>

          <span class="post-nav-divider"></span>

          <div class="post-nav-prev post-nav-item">
            
              <a href="/2018/05/02/protostuff/" rel="prev" title="更简单的使用protobuf---protostuff">
                更简单的使用protobuf---protostuff <i class="fa fa-chevron-right"></i>
              </a>
            
          </div>
        </div>
      

      
      
    </footer>
  </div>
  
  
  
  </article>


  </div>


          </div>
          

  



        </div>
        
          
  
  <div class="sidebar-toggle">
    <div class="sidebar-toggle-line-wrap">
      <span class="sidebar-toggle-line sidebar-toggle-line-first"></span>
      <span class="sidebar-toggle-line sidebar-toggle-line-middle"></span>
      <span class="sidebar-toggle-line sidebar-toggle-line-last"></span>
    </div>
  </div>

  <aside id="sidebar" class="sidebar">
    
    <div class="sidebar-inner">

      

      
        <ul class="sidebar-nav motion-element">
          <li class="sidebar-nav-toc sidebar-nav-active" data-target="post-toc-wrap">
            Table of Contents
          </li>
          <li class="sidebar-nav-overview" data-target="site-overview-wrap">
            Overview
          </li>
        </ul>
      

      <section class="site-overview-wrap sidebar-panel">
        <div class="site-overview">
          <div class="site-author motion-element" itemprop="author" itemscope itemtype="http://schema.org/Person">
            
              <p class="site-author-name" itemprop="name">文敦复</p>
              <p class="site-description motion-element" itemprop="description">思考的懒惰是真的懒惰！</p>
          </div>

          
            <nav class="site-state motion-element">
              
                <div class="site-state-item site-state-posts">
                
                  <a href="/archives/">
                
                    <span class="site-state-item-count">39</span>
                    <span class="site-state-item-name">posts</span>
                  </a>
                </div>
              

              
                
                
                <div class="site-state-item site-state-categories">
                  
                    
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                      
                    
                    <span class="site-state-item-count">37</span>
                    <span class="site-state-item-name">categories</span>
                  
                </div>
              

              
            </nav>
          

          

          

          
          

          
          

          
            
          
          

        </div>
      </section>

      
      <!--noindex-->
        <section class="post-toc-wrap motion-element sidebar-panel sidebar-panel-active">
          <div class="post-toc">

            
              
            

            
              <div class="post-toc-content"><ol class="nav"><li class="nav-item nav-level-1"><a class="nav-link" href="#内部结构"><span class="nav-number">1.</span> <span class="nav-text">内部结构</span></a><ol class="nav-child"><li class="nav-item nav-level-2"><a class="nav-link" href="#分析一"><span class="nav-number">1.1.</span> <span class="nav-text">分析一</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#分析二"><span class="nav-number">1.2.</span> <span class="nav-text">分析二</span></a></li></ol></li><li class="nav-item nav-level-1"><a class="nav-link" href="#引用的4个类型"><span class="nav-number">2.</span> <span class="nav-text">引用的4个类型</span></a></li><li class="nav-item nav-level-1"><a class="nav-link" href="#为什么要使用WeakReference"><span class="nav-number">3.</span> <span class="nav-text">为什么要使用WeakReference</span></a></li><li class="nav-item nav-level-1"><a class="nav-link" href="#内存泄露风险"><span class="nav-number">4.</span> <span class="nav-text">内存泄露风险</span></a></li><li class="nav-item nav-level-1"><a class="nav-link" href="#总结"><span class="nav-number">5.</span> <span class="nav-text">总结</span></a></li></ol></div>
            

          </div>
        </section>
      <!--/noindex-->
      

      

    </div>
  </aside>


        
      </div>
    </main>

    <footer id="footer" class="footer">
      <div class="footer-inner">
        <div class="copyright">&copy; <span itemprop="copyrightYear">2018</span>
  <span class="with-love" id="animate">
    <i class="fa fa-user"></i>
  </span>
  <span class="author" itemprop="copyrightHolder">文敦复</span>

  

  
</div>




  <div class="powered-by">Powered by <a class="theme-link" target="_blank" href="https://hexo.io">Hexo</a> v3.7.1</div>



  <span class="post-meta-divider">|</span>



  <div class="theme-info">Theme – <a class="theme-link" target="_blank" href="https://theme-next.org">NexT.Muse</a> v6.4.0</div>




        








        
      </div>
    </footer>

    
      <div class="back-to-top">
        <i class="fa fa-arrow-up"></i>
        
      </div>
    

    
	
    

    
  </div>

  

<script type="text/javascript">
  if (Object.prototype.toString.call(window.Promise) !== '[object Function]') {
    window.Promise = null;
  }
</script>


























  
  
    <script type="text/javascript" src="/lib/jquery/index.js?v=2.1.3"></script>
  

  
  
    <script type="text/javascript" src="/lib/velocity/velocity.min.js?v=1.2.1"></script>
  

  
  
    <script type="text/javascript" src="/lib/velocity/velocity.ui.min.js?v=1.2.1"></script>
  


  


  <script type="text/javascript" src="/js/src/utils.js?v=6.4.0"></script>

  <script type="text/javascript" src="/js/src/motion.js?v=6.4.0"></script>



  
  

  
  <script type="text/javascript" src="/js/src/scrollspy.js?v=6.4.0"></script>
<script type="text/javascript" src="/js/src/post-details.js?v=6.4.0"></script>



  


  <script type="text/javascript" src="/js/src/bootstrap.js?v=6.4.0"></script>



  



  










  





  

  

  

  

  
  

  

  

  

  

  

</body>
</html>
